// quantExe.cpp : Defines the entry point for the console application.
//

#include "stdafx.h"
#include "C:\TWS API\samples\Cpp\quantDll\quantDll.h"

#include <iostream>

using namespace std;


int main(int argc, char *argv[])
{
	cout << "usage: quantExe host port clientId" << endl;

	int eId = 0, eCode = 0;
	int &reId = eId, &reCode = eCode;
	std::string s = "";
	std::string &rs = s;

	int i = tws_connect(argv[1], atoi(argv[2]), atoi(argv[3]));
	if (i > 0)
		cout << "main: connected" << endl;
	else
		cout << "main: not connected" << endl;

	while (tws_isConnected())
	{
		tws_processMsgs();
		printf("quantExe:managedAccount= %s \n", tws_getManagedAccounts());
	}
	return 0;
}

